<?php

/*
|--------------------------------------------------------------------------
| Web Routes
|--------------------------------------------------------------------------
|
| Here is where you can register web routes for your application. These
| routes are loaded by the RouteServiceProvider within a group which
| contains the "web" middleware group. Now create something great!
|
*/

Route::get('/', 'IndexController@index');
Route::get('/collections/{cat}', 'CollectionController@cat');
Route::get('/search', 'CollectionController@search');
Route::get('/pages/all-categories', 'CollectionController@all');

Route::get('/products/{id}', 'GoodsController@info');
Route::get('/cart/', 'CartController@index');
Route::post('/cart/remove', 'CartController@remove');
Route::match(['get', 'post'],'/cart/checkout', 'CartController@checkout');
Route::post('/product/preview/{id}', 'GoodsController@preview');
Route::match(['get', 'post'],'/article/{name}', 'ArticleController@info');

Route::post('/order/create', 'OrderController@create');

Route::post('/paypal-complete', 'PayPalController@complete');
